<template>
	<view class="container">
		<block v-for="item in jifenList" :key="item.id">
			<view class="box">
					<view class="top">
						<text>生成时间：</text>
						<text>{{item.createTime}}</text>
					</view>
					<view class="top" style="padding-top: 20rpx;">
						<text>备注：</text>
						<text>{{item.remark}}</text>
					</view>
					<view class="footer">
						<text>积分：</text>
						<text v-if="item.operateType==1" style="color: red;font-size: 42rpx;">+</text>
						<text style="color: grey;font-size: 42rpx;" v-else>-</text>
						<text>{{item.integral}}</text>
					</view>
			</view>
		</block>
		
	</view>
</template>

<script>
import Http from '../../utils/http'
const http = new Http()
	export default {
		data() {
			return {
				jifenList:[]
			}
		},
		onLoad() {
			this.refresh()
		},
		methods: {
			async refresh(){
				uni.showLoading({
					title:"加载中..."
				})
				let res = await http.get("admin/agentShop/integralRechangeList")
				this.jifenList = res.data.data
				uni.hideLoading()
				console.log("====?",res);
			}
		}
	}
</script>

<style scoped lang="scss">
	page{
		background: #f1f1f1;
	}
	.container{
		padding-bottom: 30rpx;
	}
.box {
			padding: 20rpx 30rpx;
			background: #fff;
			margin: 30rpx 20rpx;
			border-radius: 20rpx;
              
			.top {
				padding-bottom: 16rpx;
				font-size: 28rpx;
				color: #666;
				border-bottom: 1rpx solid #f1f1f1;
			}

			.footer {
				font-size: 34rpx;
				color: #333;
				padding-top: 16rpx;
			}

			.fuzhi {
				width: 130rpx;
				height: 70rpx;
				background: #ff0000;
				text-align: center;
				color: #fff;
				font-size: 28rpx;
				line-height: 70rpx;
				border-radius: 20rpx;
			}
		}
</style>
